_Pragma("once")


#include <regex>
#include <string>
#include <utility>


#include "ExtendDevice.h"
#include "BasicDevice.h"


/**
 *
 * @author lizb
 */

 class CommandParser;

class InnerTemperatureMonitor : public ExtendDevice {
    using FloatStringPair = std::pair<float, std::string>;
public:

    InnerTemperatureMonitor(const ExtendDeviceType& deviceType);


    bool updateInformation() override;

    bool activeUpdateInformation() override;

//    bool recheck() noexcept override{
//        return activeUpdateInformation();
//    }

    /**
     * 实时功率
     */
    FloatStringPair mtemperature;

    FloatStringPair mthreshold{65.00, "65.00"};
protected:

    DeviceCommunicator mtemperatureDevice;
    DummyChannel mdummyChannel;

    uint8_t msent = 0;

    CommandParser& mcommandParser;

};

